// © 2009 Microsoft Corporation.  All rights reserved.
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ComponentModel;
using System.Collections.ObjectModel;

namespace Microsoft.InformationSecurity.ISRM.TaskManagment.Classes
{

    /// <summary>
    /// Represents as task that a user performs for a risk.
    /// </summary>
    public class Task:BusinessObject
    {

        /// <summary>
        /// Notes for the taskID.
        /// </summary>
        public string Description
        {
            get;
            set;
        }

        /// <summary>
        /// Category to which this taskID belongs to
        /// </summary>
        public Category Category
        {
            get;
            set;
        }

        /// <summary>
        /// group to which this taskID belongs to
        /// </summary>
        public Group Group
        {
            get;
            set;
        }

        /// <summary>
        /// Owner of the task who is responsible for task completion.
        /// </summary>
        public User AssignedTo
        {
            get;
            set;
        }

        /// <summary>
        /// BusinessObject to which this task is assigned to.
        /// </summary>
        public BusinessObject BusinessObject
        {
            get;
            set;
        }

        /// <summary>
        /// status of the taskID.
        /// </summary>
        public TaskStatus Status
        {
            get;
            set;
        }

        /// <summary>
        /// Date on which the taskID is dueDate
        /// </summary>
        public DateTime DueDate
        {
            get;
            set;
        }

        /// <summary>
        /// Hours spent by the owner on this taskID
        /// </summary>
        public int HoursSpent
        {
            get;
            set;
        }

        /// <summary>
        /// Tasks under this taskID, this list may contain one or more tasks.
        /// </summary>
        
        public Collection<Task> SubTasks
        {
            get;
            set;
        }

        /// <summary>
        /// Schedule of notifications for the taskID
        /// </summary>
        public NotificationSchedule NotificationSchedule
        {
            get;
            set;
        }

        /// <summary>
        /// User who last updated the task
        /// </summary>
        public string LastUpdatedBy
        {
            get;
            set;
        }

        /// <summary>
        /// Date and time when the task was last updated
        /// </summary>
        public DateTime LastUpdatedDate
        {
            get;
            set;
        }

        /// <summary>
        /// User who created the task
        /// </summary>
        public string CreatedBy
        {
            get;
            set;
        }

        /// <summary>
        /// Date and time when the task was created
        /// </summary>
        public DateTime CreatedDate
        {
            get;
            set;
        }

        /// <summary>
        /// PersonID of the person doing the action.
        /// </summary>
        public int PersonID
        {
            get;
            set;
        }

    }
}
